using SQLServices.Runners;

namespace SQLServices.Runners
{
	/// <summary>
	/// The main role of the Runner is to execute the scripts against the
	/// SQL Server database.
	/// Call the RunScripts method to execute the scripts.
	/// The class can inform of the progress back to the caller using the four
	/// different types of events.
	/// </summary>
	public interface IRunner
	{
		event ProgressMsgCreatedEventHandler ProgressMsgCreated;
		event ScriptExecErrorEventHandler ScriptExecError;
		event ScriptExecutedEventHandler ScriptExecuted;
		event ExecutionFinishedEventHandler ExecutionFinished;
		void RunScriptsAsync();
		void RunScripts();
		void CancelExecution();
	}
}